<?php
    $ping = Net_Ping::factory();
    $ping->setArgs(array('count' => 2));
    $valeurs = $ping->ping($machine->getAdresseIp());
    if($valeurs->_received === 0) {
        $criticite = Criticite::recherche(5);
        $message = 'Déconnecté';
    }
    else {
        $criticite = Criticite::recherche(1);
        $message = 'OK';
    }
?>